GtkMenuTracker: remove hidden items from the menu
authorRyan Lortie <desrt@desrt.ca>
Sat, 4 Jan 2014 07:28:39 +0000 (02:28 -0500)
committerRyan Lortie <desrt@desrt.ca>
Wed, 8 Jan 2014 19:21:19 +0000 (14:21 -0500)
commit2112af719a22a395e97b31164a3de246c7cb447e
treec6065649ab5157f5ef57b88719f41469d26910bc
parent2b1aa12f01f382652a3b6b9c7e51959dde194143
GtkMenuTracker: remove hidden items from the menu

Modify the tracker so that it manages the visibility of
GtkMenuTrackerItem by issuing insert and remove callbacks to the
user of the tracker.

This works by treating the GtkMenuTrackerItem as a virtual section which
contains 1 item when the item is visible and 0 items when it is hidden.

For efficiency reasons, we only employ this trick in the case that the
item has a hidden-when='' attribute set on it.

https://bugzilla.gnome.org/show_bug.cgi?id=688421
gtk/gtkmenutracker.c